/* 
 * Copyright 2014 ShangDao.Ltd  All rights reserved.
 * SiChuan ShangDao.Ltd PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
 * 
 * @ActWelCome.java  2014-9-16 下午4:47:03 - Carson
 * @author Guzhu
 * @email:muyi126@163.com
 * @version 1.0
 */

package com.android.tiango.baba.act;

import android.os.Bundle;
import android.os.Handler;
import android.os.Message;

import com.android.scsd.tiango.R;
import com.android.tiango.baba.BaBaseActivity;
import com.android.tiango.baba.cookie.ShareCookie;

public class ActWelcome extends BaBaseActivity {
	private Handler handler;

	@Override
	protected void onCreate(Bundle arg0) {
		super.onCreate(arg0);
		setContentView(R.layout.layout_welcome);
		onLoadInit();
	}

	private void onLoadInit() {
		handler = new Handler() {
			@Override
			public void handleMessage(Message msg) {
				super.handleMessage(msg);
				if (ShareCookie.isLoginAuth()) {
					showActivity(ActHome.class, true);
				} else {
					// TODO
					showActivity(ActTianGoBaWelcome.class, true);
				}
			}
		};
		handler.sendEmptyMessageDelayed(1, 1 * 1000);
	}

}
